#define _CRT_SECURE_NO_WARNINGS 1
#include <iostream>
using namespace std;

class Solution {
public:
    vector<string> findRelativeRanks(vector<int>& score) {
        vector<int> v1(score.begin(), score.end());
        sort(v1.begin(), v1.end(), greater<int>());
        vector<string> s1;
        for (auto& e : score)
        {
            int n = find(v1.begin(), v1.end(), e) - v1.begin() + 1;
            switch (n)
            {
            case 1:
                s1.push_back("Gold Medal");
                break;
            case 2:
                s1.push_back("Silver Medal");
                break;
            case 3:
                s1.push_back("Bronze Medal");
                break;
            default:
                s1.push_back(to_string(n));
                break;
            }
        }

        return s1;
    }
};